/*
 * @Descripttion:
 * @version:
 * @Author: kl2018
 * @Date: 2019-03-07 20:06:20
 * @LastEditors: kl2018
 * @LastEditTime: 2020-08-11 16:26:09
 */
import { Button } from 'antd';
import * as odocUtil from '../util/odocUtil';
import { WeaLocaleProvider } from 'ecCom';

const getLabel = WeaLocaleProvider.getLabel;

export default function (compStore, viewconditiondomkey, isAd) {
  return [
    (<Button ecId={`${this && this.props && this.props.ecId || ''}_Button@gy2gk6@search`}
      type="primary"
      onClick={() => { odocUtil.onSearchBtnClick(compStore, viewconditiondomkey); }}
    >
      {getLabel('388113', '搜索')}
    </Button>),
    (isAd ? null : <Button ecId={`${this && this.props && this.props.ecId || ''}_Button@zfiu0u@reset`} type="ghost" onClick={() => { compStore.adSearchForm.reset(); }}>{getLabel('2022', '重置')}</Button>),
    (isAd ? null : <Button ecId={`${this && this.props && this.props.ecId || ''}_Button@2zo3p4@cancel`} type="ghost" onClick={() => { compStore.setStoreAttr('ifShowSearchAd', false); }}>{getLabel('31129', '取消')}</Button>),
  ];
}
